/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package fr.ensisa.sunspot.actor;

import java.util.Vector;

import fr.ensisa.sunspot.IKernel;
import fr.ensisa.sunspot.event.IEvent;

/**
 * @author Michel Hassenforder
 */

public interface IActor {

    public abstract void setKernel (IKernel kernel);

    public abstract int getKind ();
    public abstract int getID ();
    public abstract boolean isActivated ();
    public abstract void setActivated (boolean activated);
    public abstract boolean canProcess (IEvent event);
    public abstract int process (long timeStamp, IEvent event);
    public abstract IEvent getGeneratedEvent();
    public abstract Vector<IEvent> getGeneratedEvents();

    public static final int KIND_READER = 1;
    public static final int KIND_FILTER = 2;
    public static final int KIND_WRITER = 3;
    public static final int KIND_SETUP  = 4;
    
    //rename
    public static final int RETURN_KILLME = 1;
    public static final int RETURN_DONOTHING = 2;
    public static final int RETURN_GETMYEVENTSANDKILLME = 3;
    public static final int RETURN_GETMYEVENTSANDDONTKILLME = 4;
    public static final int RETURN_REMOVEMEFROMTHELIST = 5;
}
